<!DOCTYPE html>
<html>
<head>
    <title>作者详情</title>
</head>
<body>
    <h1>{{ author.name }}</h1>
    <p>{{ author.bio }}</p>
    <h2>相关图书</h2>
    <ul>
        {% for book in author.book_set.all %}
            <li>{{ book.title }}</li>
        {% empty %}
            <li>暂无图书</li>
        {% endfor %}
    </ul>
    <a href="{% url 'author_list' %}">返回作者列表</a>
    <a href="{% url 'home' %}">返回主页</a>
</body>
</html>